﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace JingQiao.Ads.Domain.Model.Repository
{
    using Domain.Model.DomainObject;
    using Infrastructure;

    public interface IDestinationRepository : IRepository<IDestination>
    {
        bool IsHasAdvertisement(int destId);

        IDestination FindById(int id);

        IDestination FindBySiteName(string siteName);

        IDestination FindDefaultByConfigId(int configinfoId);

        IQueryable<IDestination> FindByIds(string destinations);

        IQueryable<IDestination> FindByRegionIds(string regionIds);

        PagedResult<IDestination> FindByParentId(int parentId, int pageSize, int pageIndex);

        int CountByParentId(int parentId);

        IQueryable<IDestination> FindAll();

        IQueryable<IDestination> FindByConfigId(int configId);

        IQueryable<IDestination> FindByConfigIdAndRegionIds(int configId, string regionIds);

        int CountByConfigIdAndRegionIds(int configId, string regionIds, string keyWord);

        PagedResult<IDestination> FindByConfigIdAndRegionIds(int configId, string regionIds, string keyWord, int pageSize, int pageIndxe);

        PagedResult<IDestination> FindByConfigId(int configId, int pageSize, int pageIndex);

        int CountByConfigId(int configId);
    }
}
